-
Notifications
You must be signed in to change notification settings - Fork 767
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: inplace update failed due to virtual kubelet in PUB #1359
Conversation
Sonatype Lift is retiringSonatype Lift will be retiring on Sep 12, 2023, with its analysis stopping on Aug 12, 2023. We understand that this news may come as a disappointment, and Sonatype is committed to helping you transition off it seamlessly. If you’d like to retain your data, please export your issues from the web console. |
Welcome @chengjoey! It looks like this is your first PR to openkruise/kruise 🎉 |
@chengjoey: GitHub didn't allow me to assign the following users: ftpilot. Note that only openkruise members, repo collaborators and people who have commented on this issue/PR can be assigned. Additionally, issues/PRs can only have 10 assignees at the same time. In response to this: Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
@@ -43,6 +44,21 @@ const ( | |||
MaxUnavailablePodSize = 2000 | |||
) | |||
|
|||
var ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about making var
together?
var (
labelNodeTypeKey = "type"
virtualNodeType = "virtual-kubelet"
taintVirtualToFind = &corev1.Taint{
Key: "virtual-kubelet.io/provider",
Effect: corev1.TaintEffectNoSchedule,
}
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
klog.Errorf("get node(%s) failed: %s", nodeName, err.Error()) | ||
return false | ||
} | ||
return node.Labels[labelNodeTypeKey] == virtualNodeType && taints.TaintExists(node.Spec.Taints, taintVirtualToFind) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there is no need to check the taints on node, virtualNode
label is enough?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done, removed the judgment of taint, virtualNode
label in enough
9dc5214
to
ff6747d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/LGTM
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: hantmac The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
This situation is still a bit more complicated, you can't skip the vk node so easily, many of our internal scenarios vk can be upgraded in place |
/hold |
ff6747d
to
15365d9
Compare
New changes are detected. LGTM label has been removed. |
Thanks! @zmberg, I added a judgment, only the pod running on the virtual node and |
15365d9
to
07f220b
Compare
skip inPlaceUpdateState check when pod is running on vk node and enable `UpdateEnvFromMetadata` Signed-off-by: joey <[email protected]>
07f220b
to
d9fcc23
Compare
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Ⅰ. Describe what this PR does
fix inplace update failed due to inplace update on vk node
skip inPlaceUpdateState check when pod is running on vk node
Ⅱ. Does this pull request fix one issue?
fix #1262
Ⅲ. Describe how to verify it
inplace update on vk node